package com.ruoyi.business.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.business.mapper.ProcesscardmainMapper;
import com.ruoyi.business.domain.Processcardmain;
import com.ruoyi.business.service.IProcesscardmainService;

/**
 * 工艺文件主Service业务层处理
 * 
 * @author DL
 * @date 2025-06-29
 */
@Service
public class ProcesscardmainServiceImpl implements IProcesscardmainService 
{
    @Autowired
    private ProcesscardmainMapper processcardmainMapper;

    /**
     * 查询工艺文件主
     * 
     * @param ID 工艺文件主主键
     * @return 工艺文件主
     */
    @Override
    public Processcardmain selectProcesscardmainByID(String ID)
    {
        return processcardmainMapper.selectProcesscardmainByID(ID);
    }

    /**
     * 查询工艺文件主列表
     * 
     * @param processcardmain 工艺文件主
     * @return 工艺文件主
     */
    @Override
    public List<Processcardmain> selectProcesscardmainList(Processcardmain processcardmain)
    {
        return processcardmainMapper.selectProcesscardmainList(processcardmain);
    }

    /**
     * 新增工艺文件主
     * 
     * @param processcardmain 工艺文件主
     * @return 结果
     */
    @Override
    public int insertProcesscardmain(Processcardmain processcardmain)
    {
        return processcardmainMapper.insertProcesscardmain(processcardmain);
    }

    /**
     * 修改工艺文件主
     * 
     * @param processcardmain 工艺文件主
     * @return 结果
     */
    @Override
    public int updateProcesscardmain(Processcardmain processcardmain)
    {
        return processcardmainMapper.updateProcesscardmain(processcardmain);
    }

    /**
     * 批量删除工艺文件主
     * 
     * @param IDs 需要删除的工艺文件主主键
     * @return 结果
     */
    @Override
    public int deleteProcesscardmainByIDs(String[] IDs)
    {
        return processcardmainMapper.deleteProcesscardmainByIDs(IDs);
    }

    /**
     * 删除工艺文件主信息
     * 
     * @param ID 工艺文件主主键
     * @return 结果
     */
    @Override
    public int deleteProcesscardmainByID(String ID)
    {
        return processcardmainMapper.deleteProcesscardmainByID(ID);
    }

    @Override
    public void updateProcesscardmainWorkState(Processcardmain processcardmain) {
       processcardmainMapper.updateProcesscardmainWorkState(processcardmain);
    }
}
